
#ifdef audioClient

#include"audioClient.hpp"

int main(int argc, char* argv[])
{
	if (argc != 5)
	{
		cout << "Error: incorrect number of arguments." << endl;
		cout << "Usage: " << argv[0] << " userAudioFile standardModel outfile write_audio(1 0r 0)" << endl;
		exit(1);
	}
	string userAudioFile = argv[1];
	string standardModel = argv[2];
	string outfile = argv[3];
	string out = argv[4];
	if (out == "0")
	{
		write_audio = false;
	}

	// method one : write the score to file
	musicScoreFollowMainWriteFile(userAudioFile, standardModel, outfile);
	/*
	// method two: return the values, which contains seven vector;
	vector<int> standardNotesId; // standard notes id
	vector<Real> standardNotesTime; //tandard notes time
	vector<int> matchUserNotesId;  //the matched user note  id
	vector<Real> matchUserNotesTime; // the matched user note time
	vector<Real> freqScore; // the score of frequency
	vector<Real> strenthScore; // the score of strenth
	vector<Real> tempoScore; // the score of tempo
	musicScoreFollowMainReturnValue(userAudioFile, standardModel,
	standardNotesId, standardNotesTime,
	matchUserNotesId, matchUserNotesTime,
	freqScore, strenthScore,
	tempoScore);*/
}
#endif

#ifdef audioServer
#include"audioServer.hpp"

int main(int argc, char* argv[])
{
	if (argc != 5)
	{
		cout << "Error: incorrect number of arguments." << endl;
		cout << "Usage: " << argv[0] << " audiofileName audioProfile outmodelName write_audio(1 0r 0)" << endl;
		exit(1);
	}
	string audiofileName = argv[1];
	string audioProfile = argv[2];
	string outmodelName = argv[3];
	string out = argv[4];
	if (out == "0")
	{
		write_audio = false;
	}
	dumpAudioFeatureToFile(audiofileName, audioProfile, outmodelName);
}
#endif
